package com.example.youmishoppingmall.mapper;

import com.example.youmishoppingmall.bean.*;

import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface GoodsMapper {
    List<GoodsConfig> selectConfigByGid(@Param("id") Integer id);
    List<GoodsColor> selectColorByGid(@Param("id")Integer id);

    //    获取全部商品包括配置和颜色
    List<GoodsDetailExample> getAll();

    //模糊查询
    List<GoodsDetailExample> likeGetGoods(@Param("like") String like);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int countByExample(GoodsExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int deleteByExample(GoodsExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int deleteByPrimaryKey(Integer id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int insert(Goods record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int insertSelective(Goods record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    List<Goods> selectByExample(GoodsExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    Goods selectByPrimaryKey(Integer id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int updateByExampleSelective(@Param("record") Goods record, @Param("example") GoodsExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int updateByExample(@Param("record") Goods record, @Param("example") GoodsExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int updateByPrimaryKeySelective(Goods record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table goods
     *
     * @mbg.generated Tue Sep 27 09:30:43 CST 2022
     */
    int updateByPrimaryKey(Goods record);
}